package io.gitee.falllee.dao.model;

/**
 * @author batty
 *
 */
public class DaoConst {
    
    private DaoConst() {}
    
    public static final String INSERT = "insert";

    public static final String INSERT_LIST = "insert-list";
    
    public static final String UPDATE = "update";
    
    public static final String UPDATE_LIST = "update-list";

    public static final String DELETE = "delete";

    public static final String DELETE_LIST = "delete-list";

    public static final String RESTORE = "restore";

    public static final String RESTORE_LIST = "restore-list";
    
    public static final String MYSQL = "mysql";
    
    public static final String MSSQL = "sqlserver";
    
    public static final String ORACLE = "oracle";
    
    public static final String POSTGRE_SQL = "postgresql";
    
    public static final String QUOTES_MYSQL = "`";
    
    public static final String QUOTES_ORACLE = "\"";
    
    public static final String QUOTES_MSSQL = "\"";
    
    public static final String QUOTES_POSTGRE_SQL = "\"";
    
    public static final String QUOTES_OTHER = "\"";
    
    public static final String SEPARATOR = "-";
    
    public static final String DATE_PATTERN = "yyyy-MM-dd";

    public static final String TABLE_NAME = "tableName";

    public static final String FIELD = "field";

    public static final String SORT = "sort";

    public static final String GROUP = "group";

    public static final String START = "start";

    public static final String END = "end";

    public static final String ROWS = "rows";

    public static final String FIELD_NAME = "fieldName";

    public static final String FILTER = "filterClause";

    public static final String KEY_FIELD = "keyField";

    public static final String KEY_VALUE = "keyValue";

    public static final String FIELD_VALUE_LIST = "fieldValueList";

    public static final String MULTI_FIELD_VALUE_LIST = "multiFieldValueList";
    
    public static final String FIELDS = "fields";
    
    public static final String VALUES = "values";
    
    public static final String ENABLE_FLAG = "enableFlag";
    
    public static final String ENABLE_FLAG_VALUE = "enableFlagValue";
    
    public static final String ENABLE_FLAG_VALUE_NO = "enableFlagValueNo";
    
    public static final String CREATE_USER = "createUser";
    
    public static final String CREATE_USER_VALUE = "createUserValue";
    
    public static final String CREATE_DATE = "createDate";
    
    public static final String UPDATE_USER = "updateUser";
    
    public static final String UPDATE_USER_VALUE = "updateUserValue";
    
    public static final String UPDATE_DATE = "updateDate";
    
    public static final String DELETE_DATE = "deleteDate";
    
    public static final String LIKE = "like";
    
    public static final String OR = "or";
    
    public static final String POINT = ".";
    
    public static final String COMMA = ",";

    /**
     * 冒号
     */
    public static final String COLON = ":";
    
    public static final String SINGLE_QUOTES = "'";
    
    public static final String REGEX_OR = "\\s(?i)or\\s";
    
    public static final String REGEX_SINGLE_QUOTES = "'.*?'"; //"'(.*?)((?<!')'(?!'))|('')+'";
    
    public static final String REGEX_PARAMETER = "#\\{[^\\{|^\\}]+\\}";
    
    public static final String REGEX_PARAMETER_PART = "#\\{.+\\}";
    
    public static final String REGEX_GENERAL = "\\(?.+[<>|>=|<=|!=|=|>|<].+\\)?";
    
    public static final String REGEX_LIKE = "\\(?.+\\s+(?i)like\\s+.+\\)?";
    
    public static final String REGEX_IN = "\\(?.+\\s+((?i)not\\s+)?(?i)in\\s*\\((.+,)*.+\\)\\)?";
    
    public static final String REGEX_SELECT = "(?i)select\\s+.+\\s+(?i)from\\s+.+";
    
    public static final String REGEX_BRACKETS = "(?<=\\()[^\\)]+";
    
    public static final String REGEX_COMMA = ",|'";
    
    public static final String REGEX_BETWEEN_AND = "\\w+\\s+(?i)between\\s+(.+?)\\s+(?i)and\\s+\\S+";
    
    public static final String SPLIT_BETWEEN_OR_AND = "\\s(?i)between\\s|\\s(?i)and\\s";
    
    public static final String SPLIT_GENERAL_OR_LIKE = "<>|>=|<=|!=|=|>|<|\\s+(?i)like\\s";
    
    public static final String SPLIT_CLAUSE = "\\s(?i)or\\s|\\s(?i)and\\s|\\s(?i)where\\s|\\s(?i)order by\\s|\\s(?i)union all\\s|\\s(?i)union\\s";
    
    public static final String SPLIT_POINT = "\\.";
    
    public static final String SPLIT_COMMA = "\\s*,\\s*";
    
    public static final String SPLIT_IN = "(\\s+((?i)not))?\\s+((?i)in)";
    
    public static final String REPLACE_BRACKETS = "\\(|\\)";

    public static final String DB_TYPE = "dbType";

    public static final String KEY_TYPE = "keyType";

    public static final String JDBC_TYPE = "jdbcType";

    public static final String FIELD_LIST = "fieldList";

    public static final String DEFAULT_DAO_CONFIG = "defaultDaoConfig";
    
    public static final String P = "p";
    
    public static final String SELECT = "select";
    
    public static final String SELECT_BY_KEY = "selectByKey";
    
    public static final String SELECT_BY_KEY_LIST = "selectByKeyList";
    
    public static final String SELECT_BY_FIELD_LIST = "selectByFieldList";
    
    public static final String SELECT_COUNT = "selectCount";
    
    public static final String SELECT_GROUP = "selectGroup";
    
    public static final String SELECT_MIN = "selectMin";
    
    public static final String SELECT_MAX = "selectMax";
    
    public static final String SELECT_DISTINCT = "selectDistinct";
    
    public static final String UPDATE_BATCH = "updateBatch";
    
    public static final String DELETE_BY_KEY = "deleteByKey";
    
    public static final String RESTORE_BY_KEY = "restoreByKey";

    public static final String CURRENT_USER = "CurrentUser";

    public static final String SQL = "sql";

    public static final String RESULT = "result";

    public static final String INCLUDE_DISABLE = "includeDisable";

    public static final String SYNC_DATE = "syncDate";

    public static final String SYNC_DATE_PRECISION = "syncDatePrecision";

    public static final String SERVICE_NAME_CONFIG = "spring.application.name";

    public static final String SYS_CODE = "spring.application.syscode";
    
    public static final String MESSAGE_SERVER = "message.server";
    
    public static final String KAFKA_HOSTS = "kafka.hosts";
    
    public static final String SPRING_KAFKA_HOSTS = "spring.kafka.hosts";

	public static final String ASTERISK = "*";
	
	public static final String ONE = "1";

    public static final String BYTE_ARRAY = "byte[]";

    public static final String FORMAT_PARAM = "#{%s}";

    public static final String KEY_FIELD_CAN_NOT_BE_NULL = "key field can not be null";

    public static final String FIELD_CAN_NOT_BE_EMPTY = "field can not be empty";

    public static final String FORMAT_THREEE = "%s%s%s";

    public static final String NO_FIELDS_MAPPING = "No fields mapping";

    public static final Integer IN_MAX_SIZE = 2000;

    public static final Long SELECT_MAX_SIZE = 5000L;

    public static final char QUOTES_CHAR = '\'';

    public static final String BRACKET = "()";

    public static final String LEFT_BRACKET = "(";

    public static final String RIGHT_BRACKET = ")";

    public static final String STRING_ZERO = "0";

    public static final String AGGREGATE = "aggregate";

    public static final String MAX = "max";

    public static final String MIN = "min";

    public static final String SUM = "sum";
    
}
